<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <base data-ice="baseUrl" href="../../../">
  <title data-ice="title">core/profile/user.js | API</title>
  <link type="text/css" rel="stylesheet" href="css/style.css">
  <link type="text/css" rel="stylesheet" href="css/prettify-tomorrow.css">
  <script src="script/prettify/prettify.js"></script>
  <script src="script/manual.js"></script>
<link rel="stylesheet" href="./inject/css/0-vue.css"><link rel="stylesheet" href="./inject/css/0-app.css"><link rel="stylesheet" href="./inject/css/0-esdoc.css"><script src="./inject/script/0-custom.js"></script><meta name="description" content="&#x4F01;&#x4E1A;&#x5373;&#x65F6;&#x901A;&#x8BAF;&#x5E73;&#x53F0;"><meta property="twitter:card" content="summary"><meta property="twitter:title" content="API"><meta property="twitter:description" content="&#x4F01;&#x4E1A;&#x5373;&#x65F6;&#x901A;&#x8BAF;&#x5E73;&#x53F0;"></head>
<body class="layout-container" data-ice="rootContainer">

<header>
  <a href="./">Home</a>
  
  <a href="identifiers.html">Reference</a>
  <a href="source.html">Source</a>
  
  <div class="search-box">
  <span>
    <img src="./image/search.png">
    <span class="search-input-edge"></span><input class="search-input"><span class="search-input-edge"></span>
  </span>
    <ul class="search-result"></ul>
  </div>
<a style="position:relative; top:3px;" href="https://github.com/easysoft/xuanxuan.git"><img width="20px" src="./image/github.png"></a></header>

<nav class="navigation" data-ice="nav"><div>
  <ul>
    
  <li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/events.js~Events.html">Events</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createCommandObject">createCommandObject</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-executeCommand">executeCommand</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-executeCommandLine">executeCommandLine</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getCommandContext">getCommandContext</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-registerCommand">registerCommand</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-setCommandContext">setCommandContext</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-unregisterCommand">unregisterCommand</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-addContextMenuCreator">addContextMenuCreator</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getInnerMenuItemsForContext">getInnerMenuItemsForContext</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getMenuItemsForContext">getMenuItemsForContext</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getMenuItemsFromCreator">getMenuItemsFromCreator</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isCreatorMatch">isCreatorMatch</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isDividerItem">isDividerItem</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-removeContextMenuCreator">removeContextMenuCreator</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-showContextMenu">showContextMenu</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-tryAddDividerItem">tryAddDividerItem</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-tryRemoveLastDivider">tryRemoveLastDivider</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-deptsSorter">deptsSorter</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-forEachMember">forEachMember</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getAllMembers">getAllMembers</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getDept">getDept</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getDeptsTree">getDeptsTree</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getMember">getMember</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getRoleName">getRoleName</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-guessMember">guessMember</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-initDepts">initDepts</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-initMembers">initMembers</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onMembersChange">onMembersChange</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-queryMembers">queryMembers</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-removeMember">removeMember</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-updateMembers">updateMembers</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isMatchWindowCondition">isMatchWindowCondition</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onNoticeUpdate">onNoticeUpdate</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-updateNotice">updateNotice</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-ready">ready</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sayReady">sayReady</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-completeDragNDrop">completeDragNDrop</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-disableGlobalShortcut">disableGlobalShortcut</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-emitAppLinkClick">emitAppLinkClick</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-enableGlobalShortcut">enableGlobalShortcut</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getUrlMeta">getUrlMeta</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isAutoLoginNextTime">isAutoLoginNextTime</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isSmallScreen">isSmallScreen</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onAppLinkClick">onAppLinkClick</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onReady">onReady</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-openUrl">openUrl</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-openUrlInApp">openUrlInApp</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-openUrlInBrowser">openUrlInBrowser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-openUrlInDialog">openUrlInDialog</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-registerShortcut">registerShortcut</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-reloadWindow">reloadWindow</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-setTitle">setTitle</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-showMobileChatsMenu">showMobileChatsMenu</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-triggerReady">triggerReady</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-unregisterGlobalShortcut">unregisterGlobalShortcut</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-contextMenuCreators">contextMenuCreators</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-DATA_CHANGE_DELAY">DATA_CHANGE_DELAY</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-events">events</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-app">app</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-depts">depts</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-members">members</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-roles">roles</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-DEFAULT">DEFAULT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-requestAttention">requestAttention</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-isReadyed">isReadyed</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-clearCopyCodeTip">clearCopyCodeTip</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-entryParams">entryParams</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-globalHotkeys">globalHotkeys</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-isGlobalShortcutDisabled">isGlobalShortcutDisabled</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-maxUrlCacheSize">maxUrlCacheSize</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-quit">quit</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-urlMetaCaches">urlMetaCaches</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#db">db</a><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/db/database.js~Database.html">Database</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-DB_VERSION">DB_VERSION</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-lastCreateDb">lastCreateDb</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-db">db</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#im">im</a><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-countChatMessages">countChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createChatMessage">createChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createCountMessagesTask">createCountMessagesTask</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-deleteLocalMessage">deleteLocalMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-forEachChat">forEachChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getAllChats">getAllChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getChat">getChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getChatCategories">getChatCategories</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getChatFiles">getChatFiles</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getChatMessages">getChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getChatMessagesInQueue">getChatMessagesInQueue</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getContactChat">getContactChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getContactsChats">getContactsChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getGroupsChats">getGroupsChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getLastActiveChat">getLastActiveChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getLastRecentChat">getLastRecentChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getOne2OneChatGid">getOne2OneChatGid</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getPublicChats">getPublicChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getRecentChats">getRecentChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-initChats">initChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-loadChatMessages">loadChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onChatMessages">onChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onChatsInit">onChatsInit</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onFetchQueueFinish">onFetchQueueFinish</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-processChatMessageQueue">processChatMessageQueue</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-queryChats">queryChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-removeChat">removeChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-saveChatMessages">saveChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-searchChatMessages">searchChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-searchChats">searchChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-updateChatMessages">updateChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-updateChats">updateChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-updatePublicChats">updatePublicChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-checkFileCache">checkFileCache</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-checkUploadFileSize">checkUploadFileSize</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-downloadFile">downloadFile</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-loadFiles">loadFiles</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-searchFiles">searchFiles</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-uploadFile">uploadFile</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-uploadImageFile">uploadImageFile</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getPlainTextOfChatMessage">getPlainTextOfChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-runChatNoticeTask">runChatNoticeTask</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatAddmember">chatAddmember</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatCategory">chatCategory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatChangename">chatChangename</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatChangepublic">chatChangepublic</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatCreate">chatCreate</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatDismiss">chatDismiss</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatGetlist">chatGetlist</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatGetpubliclist">chatGetpubliclist</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatHide">chatHide</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatHistory">chatHistory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatJoinchat">chatJoinchat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatMessage">chatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatMute">chatMute</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatNotify">chatNotify</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatSetcomitters">chatSetcomitters</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatStar">chatStar</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createBoardChatMessage">createBoardChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createChat">createChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createChatWithMembers">createChatWithMembers</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createEmojiChatMessage">createEmojiChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createLocalChatWithMembers">createLocalChatWithMembers</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createTextChatMessage">createTextChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createUrlObjectMessage">createUrlObjectMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-dimissChat">dimissChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-exitChat">exitChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-fetchChatsHistory">fetchChatsHistory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-fetchPublicChats">fetchPublicChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-handleInitChats">handleInitChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-handleReceiveChatMessages">handleReceiveChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-inviteMembersToChat">inviteMembersToChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isFetchingHistory">isFetchingHistory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-joinChat">joinChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-kickOfMemberFromChat">kickOfMemberFromChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onChatHistory">onChatHistory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onChatHistoryEnd">onChatHistoryEnd</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onChatHistoryStart">onChatHistoryStart</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onReceiveChatMessages">onReceiveChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onSendChatMessages">onSendChatMessages</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-renameChat">renameChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendBoardChatMessage">sendBoardChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendChatMessage">sendChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendEmojiMessage">sendEmojiMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendFileMessage">sendFileMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendImageAsBase64">sendImageAsBase64</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendImageMessage">sendImageMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendSocketMessageForChat">sendSocketMessageForChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendTextMessage">sendTextMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-setChatCategory">setChatCategory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-setCommitters">setCommitters</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-toggleChatPublic">toggleChatPublic</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-toggleChatStar">toggleChatStar</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-toggleHideChat">toggleHideChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-toggleMuteChat">toggleMuteChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-updateChatHistory">updateChatHistory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-activeAndMapCacheChats">activeAndMapCacheChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-activeChat">activeChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-activeLastChat">activeLastChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-captureAndCutScreenImage">captureAndCutScreenImage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatDismissConfirm">chatDismissConfirm</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatExitConfirm">chatExitConfirm</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatRenamePrompt">chatRenamePrompt</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createCatureScreenContextMenuItems">createCatureScreenContextMenuItems</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createGroupChat">createGroupChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-emitChatSendboxFocus">emitChatSendboxFocus</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-hasMessageContextMenu">hasMessageContextMenu</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isActiveChat">isActiveChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-linkMembersInText">linkMembersInText</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-mapCacheChats">mapCacheChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onActiveChat">onActiveChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onChatSendboxFocus">onChatSendboxFocus</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onRenderChatMessageContent">onRenderChatMessageContent</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onSendContentToChat">onSendContentToChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onSuggestSendImage">onSuggestSendImage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-renameChatCategory">renameChatCategory</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-renderChatMessageContent">renderChatMessageContent</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-sendContentToChat">sendContentToChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-CHATS_LIMIT_DEFAULT">CHATS_LIMIT_DEFAULT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-MAX_RECENT_TIME">MAX_RECENT_TIME</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-SEARCH_SCORE_MAP">SEARCH_SCORE_MAP</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-app">app</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-chats">chats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-fetchChatMessagesQueue">fetchChatMessagesQueue</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-isGetChatMessagesQueueBusy">isGetChatMessagesQueueBusy</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-publicChats">publicChats</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-MIN_PROGRESS_CHANGE_INTERVAL">MIN_PROGRESS_CHANGE_INTERVAL</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-lastNoticeChat">lastNoticeChat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-lastNoticeInfo">lastNoticeInfo</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-updateChatNoticeTask">updateChatNoticeTask</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-MAX_BASE64_IMAGE_SIZE">MAX_BASE64_IMAGE_SIZE</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-chatJoinTask">chatJoinTask</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-historyFetchingPager">historyFetchingPager</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-activeCaches">activeCaches</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-activedChatId">activedChatId</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-onRenderChatMessageContentListener">onRenderChatMessageContentListener</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#models">models</a><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/chat-message.js~ChatMessage.html">ChatMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/chat.js~Chat.html">Chat</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/entity-schema.js~EntitySchema.html">EntitySchema</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/entity.js~Entity.html">Entity</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/file-data.js~FileData.html">FileData</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/member.js~Member.html">Member</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/models/notification-message.js~NotificationMessage.html">NotificationMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-dataURItoBlob">dataURItoBlob</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-CONTENT_TYPES">CONTENT_TYPES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-OBJECT_TYPES">OBJECT_TYPES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-SEND_WAIT_TIME">SEND_WAIT_TIME</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-STATUS">STATUS</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-TYPES">TYPES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-COMMITTERS_TYPES">COMMITTERS_TYPES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-DISMISS_VISIBLE_TIME">DISMISS_VISIBLE_TIME</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-STATUS">STATUS</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-TYPES">TYPES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-TYPES">TYPES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-defaultValuesConveter">defaultValuesConveter</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-CATEGORIES">CATEGORIES</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-MATCH_SCORE_MAP">MATCH_SCORE_MAP</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-MATCH_SCORE_MAP">MATCH_SCORE_MAP</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-STATUS">STATUS</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#network">network</a><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/network/socket-message.js~SocketMessage.html">SocketMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/network/socket.js~AppSocket.html">AppSocket</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-checkUploadFileSize">checkUploadFileSize</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getRanzhiServerInfo">getRanzhiServerInfo</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-requestServerInfo">requestServerInfo</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-listenMessage">listenMessage</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-API">API</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-LISTEN_TIMEOUT">LISTEN_TIMEOUT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-PING_INTERVAL">PING_INTERVAL</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#profile">profile</a><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/profile/user-config.js~UserConfig.html">UserConfig</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-class">C</span><span data-ice="name"><span><a href="class/core/profile/user.js~User.html">User</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createUser">createUser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getCurrentUser">getCurrentUser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-getLastSavedUser">getLastSavedUser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isCurrentUser">isCurrentUser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onSwapUser">onSwapUser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onUserConfigChange">onUserConfigChange</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onUserStatusChange">onUserStatusChange</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-setCurrentUser">setCurrentUser</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-isPasswordWithMD5Flag">isPasswordWithMD5Flag</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-user">user</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-PASSWORD_WITH_MD5_FLAG">PASSWORD_WITH_MD5_FLAG</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#server">server</a><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-changeUserStatus">changeUserStatus</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-checkServerVersion">checkServerVersion</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-checkVersionSupport">checkVersionSupport</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-fetchUserList">fetchUserList</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-login">login</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-logout">logout</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onUserLogin">onUserLogin</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-onUserLoginout">onUserLoginout</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-tryGetTempUserInfo">tryGetTempUserInfo</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatError">chatError</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatKickoff">chatKickoff</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatLogin">chatLogin</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatLogout">chatLogout</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatSessionID">chatSessionID</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatSettings">chatSettings</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatUserChangeStatus">chatUserChangeStatus</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatUserchange">chatUserchange</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-chatUsergetlist">chatUsergetlist</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-MIN_SUPPORT_VERSION">MIN_SUPPORT_VERSION</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-TIMEOUT">TIMEOUT</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-lastGetTempUserCall">lastGetTempUserCall</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-socket">socket</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-tempUserIdList">tempUserIdList</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-variable">V</span><span data-ice="name"><span><a href="variable/index.html#static-variable-EVENT">EVENT</a></span></span></li>
<li data-ice="doc"><a data-ice="dirPath" class="nav-dir-path" href="identifiers.html#todo">todo</a><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createTodo">createTodo</a></span></span></li>
<li data-ice="doc"><span data-ice="kind" class="kind-function">F</span><span data-ice="name"><span><a href="function/index.html#static-function-createTodoFromMessage">createTodoFromMessage</a></span></span></li>
</ul>
</div>
</nav>

<div class="content" data-ice="content"><h1 data-ice="title">core/profile/user.js</h1>
<pre class="source-code line-number raw-source-code"><code class="prettyprint linenums" data-ice="content">// eslint-disable-next-line import/no-unresolved
import Platfrom from &apos;Platform&apos;;
import Md5 from &apos;md5&apos;;
import Member from &apos;../models/member&apos;;
import UserConfig from &apos;./user-config&apos;;
import DelayAction from &apos;../../utils/delay-action&apos;;
import {isSameDay, isToday} from &apos;../../utils/date-helper&apos;;
import events from &apos;../events&apos;;

/**
 * &#x7528;&#x6237;&#x5BC6;&#x7801; MD5 &#x5B58;&#x50A8;&#x524D;&#x7F00;
 * @type {string}
 * @private
 */
const PASSWORD_WITH_MD5_FLAG = &apos;%%%PWD_FLAG%%% &apos;;

/**
 * &#x4E8B;&#x4EF6;&#x8868;
 * @type {Object&lt;string, string&gt;}
 * @private
 */
const EVENT = {
    config_change: &apos;user.config.change&apos;,
    status_change: &apos;user.status.change&apos;,
    reconnect: &apos;user.reconnect&apos;,
};

/**
 * &#x68C0;&#x67E5;&#x7528;&#x6237;&#x5BC6;&#x7801;&#x5B57;&#x7B26;&#x4E32;&#x662F;&#x5426;&#x5305;&#x542B; MD5 &#x5B58;&#x50A8;&#x524D;&#x7F00;
 * @param {string} password &#x7528;&#x6237;&#x5BC6;&#x7801;
 * @return {boolean} &#x5982;&#x679C;&#x4E3A; `true` &#x8868;&#x793A;&#x7ED9;&#x5B9A;&#x7684;&#x5BC6;&#x7801;&#x5B57;&#x7B26;&#x4E32;&#x5305;&#x542B; MD5 &#x5B58;&#x50A8;&#x524D;&#x7F00;&#xFF0C;&#x5426;&#x5219;&#x4E0D;&#x662F;
 */
export const isPasswordWithMD5Flag = password =&gt; password &amp;&amp; password.startsWith(PASSWORD_WITH_MD5_FLAG);

/**
 * &#x7528;&#x6237;&#x7C7B;
 *
 * @class User
 * @extends {Member}
 */
export default class User extends Member {
    /**
     * &#x4E8B;&#x4EF6;&#x8868;
     * @type {Object&lt;string, string&gt;}
     * @static
     * @memberof User
     */
    static EVENT = EVENT;

    /**
     * &#x6570;&#x636E;&#x5E93;&#x5B58;&#x50A8;&#x5B9E;&#x4F53;&#x5C5E;&#x6027;&#x7ED3;&#x6784;&#x7BA1;&#x7406;&#x5668;
     *
     * @type {EntitySchema}
     * @static
     * @memberof User
     */
    static SCHEMA = Member.SCHEMA.extend({
        lastLoginTime: {type: &apos;timestamp&apos;},
        config: {type: &apos;object&apos;, defaultValue: {}},
        password: {type: &apos;string&apos;},
        token: {type: &apos;string&apos;},
        cipherIV: {type: &apos;string&apos;},
        server: {type: &apos;string&apos;},
        serverVersion: {type: &apos;string&apos;},
        uploadFileSize: {type: &apos;int&apos;},
        autoLogin: {type: &apos;boolean&apos;, default: false},
        rememberPassword: {type: &apos;boolean&apos;, default: true},
        signed: {
            type: &apos;timestamp&apos;,
            setter: (time, obj) =&gt; {
                const lastSignedTime = obj.signed;
                obj._isFirstSignedToday = time &amp;&amp; isToday(time) &amp;&amp; (!lastSignedTime || !isSameDay(time, lastSignedTime));
                return time;
            }
        },
    });

    /**
     * &#x7528;&#x6237;&#x72B6;&#x6001;&#x7BA1;&#x7406;&#x5668;
     *
     * @type {Status}
     * @static
     * @memberof User
     */
    static STATUS = Member.STATUS;

    /**
     * &#x521B;&#x5EFA;&#x4E00;&#x4E2A;&#x7528;&#x6237;&#x7C7B;&#x5B9E;&#x4F8B;
     * @param {Object&lt;string, any&gt;} data &#x5C5E;&#x6027;&#x5BF9;&#x8C61;
     * @memberof User
     */
    constructor(data) {
        super(data);

        /**
         * &#x7528;&#x6237;&#x4FDD;&#x5B58;&#x5EF6;&#x8FDF;&#x64CD;&#x4F5C;&#x7BA1;&#x7406;&#x5668;
         * @type {DelayAction}
         * @private
         */
        this.saveUserAction = new DelayAction(() =&gt; {
            Platfrom.config.saveUser(this);
        });

        /**
         * &#x4E8B;&#x4EF6;&#x673A;&#x5236;&#x662F;&#x5426;&#x53EF;&#x7528;
         * @private
         * @type {boolean}
         */
        this.eventsEnable = false;

        this._status.onChange = (status, oldStatus) =&gt; {
            if (this.isEventsEnable) {
                events.emit(EVENT.status_change, status, oldStatus, this);
            }

            clearTimeout(this.statusChangeCallTimer);
            if (this._status.is(Member.STATUS.logined)) {
                this.$set(&apos;lastLoginTime&apos;, new Date().getTime());
                this.statusChangeCallTimer = setTimeout(() =&gt; {
                    this.status = Member.STATUS.online;
                }, 1000);
            }
        };
    }


    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x7C7B;&#x6570;&#x636E;&#x5E93;&#x5B58;&#x50A8;&#x5B9E;&#x4F53;&#x5C5E;&#x6027;&#x7ED3;&#x6784;&#x7BA1;&#x7406;&#x5668;
     *
     * @readonly
     * @memberof User
     * @type {EntitySchema}
     */
    // eslint-disable-next-line class-methods-use-this
    get schema() {
        return User.SCHEMA;
    }

    /**
     * &#x5224;&#x5B9A;&#x5F53;&#x524D;&#x7528;&#x6237;&#x4E8B;&#x4EF6;&#x673A;&#x5236;&#x662F;&#x5426;&#x53EF;&#x7528;
     *
     * @readonly
     * @memberof User
     * @type {boolean}
     */
    get isEventsEnable() {
        return this.eventsEnable;
    }

    /**
     * &#x5C06;&#x5F53;&#x524D;&#x7528;&#x6237;&#x4E8B;&#x4EF6;&#x673A;&#x5236;&#x6807;&#x8BB0;&#x4E3A;&#x53EF;&#x7528;
     *
     * @memberof User
     * @return {void}
     */
    enableEvents() {
        this.eventsEnable = true;
    }

    /**
     * &#x9500;&#x6BC1;&#x5F53;&#x524D;&#x7528;&#x6237;&#x5B9E;&#x4F8B;&#xFF0C;&#x5E76;&#x5C06;&#x5F53;&#x524D;&#x7528;&#x6237;&#x4E8B;&#x4EF6;&#x673A;&#x5236;&#x6807;&#x8BB0;&#x4E3A;&#x4E0D;&#x53EF;&#x7528;
     *
     * @memberof User
     * @return {void}
     */
    destroy() {
        this.eventsEnable = false;
    }

    /**
     * &#x83B7;&#x53D6;&#x5F53;&#x524D;&#x7528;&#x6237;&#x5B9E;&#x4F8B;&#x5B58;&#x50A8;&#x6570;&#x636E;&#x5BF9;&#x8C61;
     *
     * @return {Object&lt;string, any&gt;} &#x6570;&#x636E;&#x5BF9;&#x8C61;
     * @memberof User
     */
    plain() {
        return Object.assign({}, this.$, {
            config: this.config.plain()
        });
    }

    /**
     * &#x5C06;&#x7528;&#x6237;&#x4FDD;&#x5B58;&#x5230;&#x672C;&#x5730;&#x5B58;&#x50A8;
     *
     * @memberof User
     * @return {void}
     */
    save() {
        this.saveUserAction.do();
    }

    /**
     * &#x5224;&#x5B9A;&#x7528;&#x6237;&#x662F;&#x5426;&#x5728;&#x4ECA;&#x5929;&#x7B2C;&#x4E00;&#x6B21;&#x8FDB;&#x884C;&#x767B;&#x5F55;
     *
     * @readonly
     * @memberof User
     * @type {boolean}
     */
    get isFirstSignedToday() {
        return !!this._isFirstSignedToday;
    }

    /**
     * &#x5224;&#x5B9A;&#x7528;&#x6237;&#x662F;&#x5426;&#x6210;&#x529F;&#x767B;&#x5F55;&#x8FC7;
     *
     * @memberof User
     * @type {boolean}
     */
    get signed() {
        return this.$get(&apos;signed&apos;);
    }

    /**
     * &#x8BBE;&#x7F6E;&#x7528;&#x6237;&#x4E0A;&#x6B21;&#x767B;&#x5F55;&#x65F6;&#x95F4;
     *
     * @memberof User
     * @param {number} time &#x4E0A;&#x6B21;&#x767B;&#x5F55;&#x65F6;&#x95F4;&#x6233;
     */
    set signed(time) {
        return this.$set(&apos;signed&apos;, time);
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x4E2A;&#x4EBA;&#x914D;&#x7F6E;&#x6570;&#x636E;
     *
     * @readonly
     * @memberof User
     * @return {Object&lt;string, any&gt;} &#x914D;&#x7F6E;&#x6570;&#x636E;&#x5BF9;&#x8C61;
     */
    get config() {
        if (!this._config) {
            this._config = new UserConfig(this.$get(&apos;config&apos;));
            this._config.onChange = (change, config) =&gt; {
                // Save user to config file
                this.save();

                // Emit user config change event
                if (this.isEventsEnable) {
                    events.emit(EVENT.config_change, change, config, this);
                }
            };
        }
        return this._config;
    }

    /**
     * &#x5224;&#x65AD;&#x7528;&#x6237;&#x72B6;&#x6001;&#x662F;&#x5426;&#x5904;&#x4E8E;&#x79BB;&#x7EBF;&#x72B6;&#x6001;
     *
     * @readonly
     * @memberof User
     * @return {boolean} &#x5982;&#x679C;&#x4E3A; `true` &#x5219;&#x8868;&#x793A;&#x7528;&#x6237;&#x5904;&#x4E8E;&#x79BB;&#x7EBF;&#x72B6;&#x6001;&#xFF0C;&#x5426;&#x5219;&#x4E3A;&#x4E3A;&#x901A;&#x8FC7;&#x9A8C;&#x8BC1;&#x6216;&#x5728;&#x7EBF;&#x72B6;&#x6001;
     */
    get isDisconnect() {
        return this._status.is(Member.STATUS.disconnect);
    }

    /**
     * &#x5224;&#x65AD;&#x7528;&#x6237;&#x72B6;&#x6001;&#x662F;&#x5426;&#x5904;&#x4E8E;&#x672A;&#x901A;&#x8FC7;&#x9A8C;&#x8BC1;&#x72B6;&#x6001;
     *
     * @readonly
     * @memberof User
     * @return {boolean} &#x5982;&#x679C;&#x4E3A; `true` &#x5219;&#x8868;&#x793A;&#x7528;&#x6237;&#x5904;&#x4E8E;&#x672A;&#x901A;&#x8FC7;&#x9A8C;&#x8BC1;&#x72B6;&#x6001;
     */
    get isUnverified() {
        return this.status &lt;= Member.STATUS.unverified;
    }

    /**
     * &#x5224;&#x65AD;&#x7528;&#x6237;&#x72B6;&#x6001;&#x662F;&#x5426;&#x5904;&#x4E8E;&#x5DF2;&#x901A;&#x8FC7;&#x9A8C;&#x8BC1;&#x72B6;&#x6001;
     *
     * @readonly
     * @memberof User
     * @return {boolean}
     */
    get isVertified() {
        return this.status &gt;= Member.STATUS.disconnect;
    }

    /**
     * &#x5224;&#x65AD;&#x7528;&#x6237;&#x72B6;&#x6001;&#x662F;&#x5426;&#x5904;&#x4E8E;&#x5DF2;&#x767B;&#x5F55;&#x72B6;&#x6001;
     *
     * @readonly
     * @memberof User
     * @return {boolean}
     */
    get isLogined() {
        return this.status &gt;= Member.STATUS.logined;
    }

    /**
     * &#x5C06;&#x7528;&#x6237;&#x767B;&#x5F55;&#x72B6;&#x6001;&#x8BBE;&#x7F6E;&#x4E3A;&#x79BB;&#x7EBF;&#x72B6;&#x6001;
     *
     * @memberof User
     * @return {void}
     */
    markDisconnect() {
        this.status = Member.STATUS.disconnect;
    }

    /**
     * &#x5C06;&#x7528;&#x6237;&#x767B;&#x5F55;&#x72B6;&#x6001;&#x8BBE;&#x7F6E;&#x4E3A;&#x672A;&#x901A;&#x8FC7;&#x9A8C;&#x8BC1;&#x72B6;&#x6001;
     *
     * @memberof User
     * @return {void}
     */
    markUnverified() {
        this.status = Member.STATUS.unverified;
    }

    /**
     * &#x5224;&#x65AD;&#x7528;&#x6237;&#x72B6;&#x6001;&#x662F;&#x5426;&#x5904;&#x4E8E;&#x6B63;&#x5728;&#x767B;&#x5F55;&#x4E2D;&#x72B6;&#x6001;
     *
     * @readonly
     * @memberof User
     * @return {boolean}
     */
    get isLogging() {
        return this._isLogging;
    }

    /**
     * &#x6807;&#x8BB0;&#x7528;&#x6237;&#x6B63;&#x5728;&#x5F00;&#x59CB;&#x767B;&#x5F55;&#x64CD;&#x4F5C;
     *
     * @memberof User
     * @return {void}
     */
    beginLogin() {
        this._isLogging = true;
    }

    /**
     * &#x6807;&#x8BB0;&#x7528;&#x6237;&#x5DF2;&#x7ED3;&#x675F;&#x767B;&#x5F55;&#x64CD;&#x4F5C;
     *
     * @param {boolean} result &#x662F;&#x5426;&#x767B;&#x5F55;&#x6210;&#x529F;
     * @memberof User
     * @return {void}
     */
    endLogin(result) {
        this._isLogging = false;
        if (result) {
            this.status = Member.STATUS.logined;
        } else if (!this.isDisconnect) {
            this.status = Member.STATUS.unverified;
        }
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x53EF;&#x7528;&#x7684; Session ID
     *
     * @memberof User
     * @type {string}
     */
    get sessionID() {
        return this._sessionID;
    }

    /**
     * &#x8BBE;&#x7F6E;&#x7528;&#x6237;&#x53EF;&#x7528;&#x7684; Session ID
     *
     * @param {string} sessionID Session ID
     * @memberof User
     */
    set sessionID(sessionID) {
        this._sessionID = sessionID;
    }

    /**
     * &#x8BBE;&#x7F6E;&#x7528;&#x6237;&#x767B;&#x5F55;&#x7684;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;
     *
     * @memberof User
     * @param {string} server &#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;
     */
    set server(server) {
        if (server) {
            if (!server.startsWith(&apos;https://&apos;) &amp;&amp; !server.startsWith(&apos;http://&apos;)) {
                server = `https://${server}`;
            }
            const url = new URL(server);
            if (!url.port) {
                url.port = 11443;
            }
            this.$set(&apos;server&apos;, url.toString());
            this._server = url;
        }
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x767B;&#x5F55;&#x7684;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;&#xFF08;&#x4EE5; URL &#x5B9E;&#x4F8B;&#x5F62;&#x5F0F;&#xFF09;
     *
     * @type {URL}
     * @memberof User
     */
    get server() {
        if (!this._server) {
            this.server = this.$get(&apos;server&apos;);
        }
        return this._server;
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x767B;&#x5F55;&#x7684;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;&#xFF08;&#x4EE5;&#x5B57;&#x7B26;&#x4E32;&#x5F62;&#x5F0F;&#xFF09;
     *
     * @readonly
     * @memberof User
     * @type {string}
     */
    get serverUrl() {
        const {server} = this;
        return server &amp;&amp; server.toString();
    }

    /**
     * &#x83B7;&#x53D6;&#x7136;&#x4E4B;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;
     *
     * @memberof User
     * @type {string}
     */
    get ranzhiUrl() {
        if (this._ranzhiUrl === undefined) {
            this._ranzhiUrl = this.$get(&apos;ranzhiUrl&apos;) || `http://${this.server.hostname}`;
        }
        return this._ranzhiUrl;
    }

    /**
     * &#x8BBE;&#x7F6E;&#x7136;&#x4E4B;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;
     *
     * @memberof User
     * @param {string} url &#x7136;&#x4E4B;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;
     */
    set ranzhiUrl(url) {
        this._ranzhiUrl = url;
    }

    /**
     * &#x83B7;&#x53D6; XXD &#x670D;&#x52A1;&#x5668;&#x7AEF;&#x53E3;&#x53F7;
     *
     * @readonly
     * @memberof User
     * @type {string}
     */
    get webServerPort() {
        const {server} = this;
        return server ? server.port : &apos;&apos;;
    }

    /**
     * &#x83B7;&#x53D6;&#x8981;&#x767B;&#x5F55;&#x7684; XXD &#x670D;&#x52A1;&#x5668;&#x540D;&#x79F0;
     *
     * @readonly
     * @memberof User
     * @type {string}
     */
    get serverName() {
        const {server} = this;
        if (server) {
            // eslint-disable-next-line no-nested-ternary
            return server.username ? server.username : (server.pathname ? server.pathname.substr(1) : &apos;&apos;);
        }
        return &apos;&apos;;
    }

    /**
     * &#x83B7;&#x53D6;&#x8BF7;&#x6C42; XXD &#x670D;&#x52A1;&#x5668;&#x4FE1;&#x606F; URL &#x5730;&#x5740;
     *
     * @readonly
     * @memberof User
     * @type {string}
     */
    get webServerInfoUrl() {
        const {server} = this;
        return server ? `${server.origin}/serverInfo` : &apos;&apos;;
    }

    /**
     * &#x83B7;&#x53D6; Socket &#x670D;&#x52A1;&#x5668;&#x7AEF;&#x53E3;
     *
     * @memberof User
     * @type {string}
     */
    get socketPort() {
        return this._socketPort || &apos;&apos;;
    }

    /**
     * &#x8BBE;&#x7F6E; Socket &#x670D;&#x52A1;&#x5668;&#x7AEF;&#x53E3;
     *
     * @memberof User
     */
    set socketPort(port) {
        this._socketPort = port;
    }

    /**
     * &#x83B7;&#x53D6; Socket &#x670D;&#x52A1;&#x8FDE;&#x63A5;&#x5730;&#x5740;
     *
     * @memberof User
     * @type {string}
     */
    get socketUrl() {
        if (this._socketUrl) {
            return this._socketUrl;
        }
        const {serverUrl} = this;
        if (serverUrl) {
            const url = new URL(serverUrl);
            url.protocol = (this.isVersionSupport(&apos;wss&apos;) &amp;&amp; url.protocol === &apos;https:&apos;) ? &apos;wss:&apos; : &apos;ws:&apos;;
            url.pathname = &apos;/ws&apos;;
            url.port = this.socketPort;
            return url.toString();
        }
        return &apos;&apos;;
    }

    /**
     * &#x8BBE;&#x7F6E;Socket &#x670D;&#x52A1;&#x5668;&#x8FDE;&#x63A5;&#x5730;&#x5740;
     *
     * @param {string} url Socket &#x670D;&#x52A1;&#x5668;&#x8FDE;&#x63A5;&#x5730;&#x5740;
     * @memberof User
     */
    set socketUrl(url) {
        this._socketUrl = url;
    }

    /**
     * &#x83B7;&#x53D6;&#x670D;&#x52A1;&#x5668;&#x7248;&#x672C;
     *
     * @memberof User
     * @type {string}
     */
    get serverVersion() {
        return this._serverVersion;
    }

    /**
     * &#x8BBE;&#x7F6E;&#x670D;&#x52A1;&#x5668;&#x7248;&#x672C;&#x53F7;
     *
     * @param {string} version &#x670D;&#x52A1;&#x5668;&#x7248;&#x672C;&#x53F7;
     * @memberof User
     */
    set serverVersion(version) {
        version = version.toLowerCase();
        if (version[0] === &apos;v&apos;) {
            version = version.substr(1);
        }
        this._serverVersion = version;
    }

    /**
     * &#x83B7;&#x53D6;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;&#x6839;&#x8DEF;&#x5F84;
     *
     * @memberof User
     * @type {string}
     */
    get serverUrlRoot() {
        const {serverUrl} = this;
        let urlRoot = &apos;&apos;;
        if (serverUrl) {
            const url = new URL(serverUrl);
            url.hash = &apos;&apos;;
            url.search = &apos;&apos;;
            url.pathname = &apos;&apos;;
            urlRoot = url.toString();
        }
        if (urlRoot &amp;&amp; !urlRoot.endsWith(&apos;/&apos;)) {
            urlRoot += &apos;/&apos;;
        }
        return urlRoot;
    }

    /**
     * &#x62FC;&#x63A5; http &#x670D;&#x52A1;&#x5668;&#x8BF7;&#x6C42;&#x5730;&#x5740;
     * @param {string} [path=&apos;&apos;] &#x8BF7;&#x6C42;&#x8DEF;&#x5F84;
     * @memberof User
     * @return {void}
     */
    makeServerUrl(path = &apos;&apos;) {
        if (path &amp;&amp; path.startsWith(&apos;/&apos;)) {
            path = path.substr(1);
        }
        return this.serverUrlRoot + path;
    }

    /**
     * &#x83B7;&#x53D6;&#x4E0A;&#x4F20;&#x6587;&#x4EF6;&#x8BF7;&#x6C42;&#x5730;&#x5740;
     *
     * @memberof User
     * @type {string}
     */
    get uploadUrl() {
        return this.makeServerUrl(&apos;upload&apos;);
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x6807;&#x8BC6;&#x5B57;&#x7B26;&#x4E32;
     *
     * @memberof User
     * @type {string}
     */
    get identify() {
        const {server} = this;
        if (!server) {
            return &apos;&apos;;
        }
        return User.createIdentify(server, this.account);
    }

    /**
     * &#x83B7;&#x53D6; Socket &#x52A0;&#x5BC6; Token &#x5B57;&#x7B26;&#x4E32;
     *
     * @memberof User
     * @type {string}
     */
    get token() {
        return this.$get(&apos;token&apos;);
    }

    /**
     * &#x8BBE;&#x7F6E; Socket &#x52A0;&#x5BC6; Token &#x5B57;&#x7B26;&#x4E32;
     *
     * @param {string} token  Socket &#x52A0;&#x5BC6; Token &#x5B57;&#x7B26;&#x4E32;
     * @memberof User
     */
    set token(token) {
        this.$set(&apos;token&apos;, token);
    }

    /**
     * &#x83B7;&#x53D6; Socket &#x670D;&#x52A1; AES &#x52A0;&#x5BC6;&#x5411;&#x91CF;
     *
     * @memberof User
     * @type {string}
     */
    get cipherIV() {
        return this.token.substr(0, 16);
        // let cipherIV = this.$get(&apos;cipherIV&apos;);
        // if(!cipherIV) {
        //     cipherIV = this.token.substr(0, 16);
        // }
        // return cipherIV;
    }

    /**
     * &#x8BBE;&#x7F6E; Socket &#x670D;&#x52A1; AES &#x52A0;&#x5BC6;&#x5411;&#x91CF;
     *
     * @memberof User
     * @param {string} cipherIV Socket &#x670D;&#x52A1; AES &#x52A0;&#x5BC6;&#x5411;&#x91CF;
     */
    set cipherIV(cipherIV) {
        this.$set(&apos;cipherIV&apos;, cipherIV);
    }

    /**
     * &#x83B7;&#x53D6;&#x6700;&#x5927;&#x5141;&#x8BB8;&#x6587;&#x4EF6;&#x4E0A;&#x4F20;&#x5927;&#x5C0F;
     *
     * @memberof User
     * @type {number}
     */
    get uploadFileSize() {
        return this.$get(&apos;uploadFileSize&apos;);
    }

    /**
     * &#x8BBE;&#x7F6E;&#x6700;&#x5927;&#x5141;&#x8BB8;&#x6587;&#x4EF6;&#x4E0A;&#x4F20;&#x5927;&#x5C0F;
     *
     * @param {number} uploadFileSize &#x6700;&#x5927;&#x5141;&#x8BB8;&#x6587;&#x4EF6;&#x4E0A;&#x4F20;&#x5927;&#x5C0F;
     * @memberof User
     */
    set uploadFileSize(uploadFileSize) {
        this.$set(&apos;uploadFileSize&apos;, uploadFileSize);
    }

    /**
     * &#x83B7;&#x53D6;&#x4E0A;&#x6B21;&#x767B;&#x5F55;&#x7684;&#x65F6;&#x95F4;&#x6233;
     *
     * @memberof User
     * @type {number}
     * @readonly
     */
    get lastLoginTime() {
        return this.$get(&apos;lastLoginTime&apos;);
    }

    /**
     * &#x83B7;&#x53D6;&#x662F;&#x5426;&#x5DF2;&#x8BBE;&#x7F6E;&#x4E3A;&#x81EA;&#x52A8;&#x767B;&#x5F55;
     *
     * @memberof User
     * @type {boolean}
     */
    get autoLogin() {
        return this.$get(&apos;autoLogin&apos;);
    }

    /**
     * &#x8BBE;&#x7F6E;&#x662F;&#x5426;&#x5DF2;&#x8BBE;&#x7F6E;&#x4E3A;&#x81EA;&#x52A8;&#x767B;&#x5F55;
     *
     * @param {boolean} autoLogin &#x662F;&#x5426;&#x5DF2;&#x8BBE;&#x7F6E;&#x4E3A;&#x81EA;&#x52A8;&#x767B;&#x5F55;
     * @memberof User
     */
    set autoLogin(autoLogin) {
        this.$set(&apos;autoLogin&apos;, autoLogin);
    }

    /**
     * &#x83B7;&#x53D6;&#x662F;&#x5426;&#x8BBE;&#x7F6E;&#x4E3A;&#x8BB0;&#x4F4F;&#x5BC6;&#x7801;
     *
     * @memberof User
     * @type {boolean}
     */
    get rememberPassword() {
        return this.$get(&apos;rememberPassword&apos;);
    }

    /**
     * &#x8BBE;&#x7F6E;&#x662F;&#x5426;&#x8BBE;&#x7F6E;&#x4E3A;&#x8BB0;&#x4F4F;&#x5BC6;&#x7801;
     *
     * @param {boolean} rememberPassword &#x662F;&#x5426;&#x8BBE;&#x7F6E;&#x4E3A;&#x8BB0;&#x4F4F;&#x5BC6;&#x7801;
     * @memberof User
     */
    set rememberPassword(rememberPassword) {
        this.$set(&apos;rememberPassword&apos;, rememberPassword);
    }

    /**
     * &#x83B7;&#x53D6;&#x662F;&#x5426;&#x5F00;&#x542F; LDAP &#x767B;&#x5F55;&#x6A21;&#x5F0F;
     *
     * @memberof User
     * @type {boolean}
     */
    get ldap() {
        return this.$get(&apos;ldap&apos;);
    }

    /**
     * &#x8BBE;&#x7F6E;&#x662F;&#x5426;&#x5F00;&#x542F; LDAP &#x767B;&#x5F55;&#x6A21;&#x5F0F;
     *
     * @param {boolean} ldap &#x662F;&#x5426;&#x5F00;&#x542F; LDAP &#x767B;&#x5F55;&#x6A21;&#x5F0F;
     * @memberof User
     */
    set ldap(ldap) {
        this.$set(&apos;ldap&apos;, ldap);
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x5934;&#x50CF;&#x56FE;&#x7247;&#x5730;&#x5740;
     *
     * @memberof User
     * @type {string}
     */
    get avatar() {
        let avatar = this._avatar;
        if (!avatar) {
            avatar = this.$get(&apos;avatar&apos;);
            if (avatar) {
                if (!avatar.startsWith(&apos;https://&apos;) &amp;&amp; !avatar.startsWith(&apos;http://&apos;)) {
                    avatar = this.serverUrlRoot + avatar;
                }
            }
        }
        return avatar;
    }

    /**
     * &#x8BBE;&#x7F6E;&#x7528;&#x6237;&#x5934;&#x50CF;&#x56FE;&#x7247;&#x5730;&#x5740;
     *
     * @param {string} newAvatar &#x7528;&#x6237;&#x5934;&#x50CF;&#x56FE;&#x7247;&#x5730;&#x5740;
     * @memberof User
     */
    set avatar(newAvatar) {
        this._avatar = null;
        this.$set(&apos;avatar&apos;, newAvatar);
    }

    /**
     * &#x83B7;&#x53D6;&#x662F;&#x5426;&#x4ECE;&#x6CA1;&#x6709;&#x6210;&#x529F;&#x767B;&#x5F55;&#x8FC7;
     *
     * @memberof User
     * @type {boolean}
     * @readonly
     */
    get isNeverLogined() {
        return !this.lastLoginTime;
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x6237;&#x5BC6;&#x7801;
     *
     * @memberof User
     * @type {string}
     */
    get password() {
        return this.$get(&apos;password&apos;);
    }

    /**
     * &#x83B7;&#x53D6;&#x5305;&#x542B; MD5 &#x524D;&#x7F00;&#x7684;&#x5BC6;&#x7801;
     *
     * @memberof User
     * @type {string}
     */
    get passwordMD5WithFlag() {
        let {password} = this;
        if (password &amp;&amp; !isPasswordWithMD5Flag(password)) {
            password = PASSWORD_WITH_MD5_FLAG + password;
        }
        return password;
    }

    /**
     * &#x83B7;&#x53D6;&#x7528;&#x4E8E;&#x767B;&#x5F55;&#x9A8C;&#x8BC1;&#x7684;&#x5BC6;&#x7801;
     *
     * @memberof User
     * @type {string}
     * @readonly
     */
    get passwordForServer() {
        return this.ldap ? this.password : this.passwordMD5;
    }

    /**
     * &#x83B7;&#x53D6; MD5 &#x7B97;&#x6CD5;&#x52A0;&#x5BC6;&#x540E;&#x7684;&#x5BC6;&#x7801;
     *
     * @memberof User
     * @type {string}
     * @readonly
     */
    get passwordMD5() {
        let {password} = this;
        if (isPasswordWithMD5Flag(password)) {
            password = password.substr(PASSWORD_WITH_MD5_FLAG.length);
        } else {
            password = Md5(password);
        }
        return password;
    }

    /**
     * &#x8BBE;&#x7F6E;&#x7528;&#x6237;&#x5BC6;&#x7801;&#xFF0C;&#x652F;&#x6301;&#x8BBE;&#x7F6E;&#x539F;&#x59CB;&#x5BC6;&#x7801;&#x6216;&#x8005;&#x5DF2;&#x6DFB;&#x52A0; MD5 &#x524D;&#x7F00;&#x7684;&#x52A0;&#x5BC6;&#x540E;&#x7684;&#x5BC6;&#x7801;
     *
     * @param {string} newPassword &#x7528;&#x6237;&#x5BC6;&#x7801;&#xFF0C;&#x652F;&#x6301;&#x8BBE;&#x7F6E;&#x539F;&#x59CB;&#x5BC6;&#x7801;&#x6216;&#x8005;&#x5DF2;&#x6DFB;&#x52A0; MD5 &#x524D;&#x7F00;&#x7684;&#x52A0;&#x5BC6;&#x540E;&#x7684;&#x5BC6;&#x7801;
     * @memberof User
     */
    set password(newPassword) {
        if (!this.ldap &amp;&amp; newPassword &amp;&amp; !isPasswordWithMD5Flag(newPassword)) {
            newPassword = PASSWORD_WITH_MD5_FLAG + Md5(newPassword);
        }
        this.$set(&apos;password&apos;, newPassword);
    }

    /**
     * &#x68C0;&#x67E5;&#x5F53;&#x524D;&#x7248;&#x672C;&#x662F;&#x5426;&#x652F;&#x6301;&#x7279;&#x5B9A;&#x529F;&#x80FD;
     *
     * @param {string} name &#x529F;&#x80FD;&#x540D;&#x79F0;
     * @return {boolean}
     * @memberof User
     */
    isVersionSupport(name) {
        return this._versionSupport &amp;&amp; this._versionSupport[name];
    }

    /**
     * &#x8BBE;&#x7F6E;&#x5F53;&#x524D;&#x670D;&#x52A1;&#x5668;&#x7248;&#x672C;&#x652F;&#x6301;&#x7684;&#x529F;&#x80FD;&#x8868;
     *
     * @param {Object&lt;string, boolean&gt;} flags &#x652F;&#x6301;&#x7684;&#x529F;&#x80FD;&#x8868;
     * @memberof User
     */
    setVersionSupport(flags) {
        if (flags) {
            if (!this._versionSupport) {
                this._versionSupport = {};
            }
            Object.assign(this._versionSupport, flags);
        }
    }

    /**
     * &#x521B;&#x5EFA;&#x4E00;&#x4E2A;&#x7528;&#x6237;&#x5B9E;&#x4F8B;
     *
     * @static
     * @param {Object|User} user &#x7528;&#x6237;&#x6570;&#x636E;&#x5BF9;&#x8C61;
     * @return {User}
     * @memberof User
     */
    static create(user) {
        if (user instanceof User) {
            return user;
        }
        return new User(user);
    }

    /**
     * &#x521B;&#x5EFA;&#x7528;&#x6237;&#x552F;&#x4E00;&#x8BC6;&#x522B;&#x6807;&#x8BC6;&#x5B57;&#x7B26;&#x4E32;
     *
     * @static
     * @param {string} server &#x7528;&#x6237;&#x767B;&#x5F55;&#x7684;&#x670D;&#x52A1;&#x5668;&#x5730;&#x5740;
     * @param {string} account &#x7528;&#x6237;&#x8D26;&#x53F7;
     * @return {string}
     * @memberof User
     */
    static createIdentify(server, account) {
        if (!(server instanceof URL)) {
            if (!server.startsWith(&apos;https://&apos;) &amp;&amp; !server.startsWith(&apos;http://&apos;)) {
                server = `https://${server}`;
            }
            server = new URL(server);
        }
        if (!server.port) {
            server.port = 11443;
        }
        let {pathname} = server;
        if (pathname &amp;&amp; pathname.length) {
            if (pathname === &apos;/&apos;) {
                pathname = &apos;&apos;;
            }
            pathname = pathname.replace(/\//g, &apos;_&apos;);
        }
        const hostname = server.host.replace(&apos;:&apos;, &apos;__&apos;);
        return `${account}@${hostname}${pathname}`;
    }
}
</code></pre>

</div>

<footer class="footer">
  Generated by <a href="https://esdoc.org">ESDoc<span data-ice="esdocVersion">(1.1.0)</span><img src="./image/esdoc-logo-mini-black.png"></a>
</footer>

<script src="script/search_index.js"></script>
<script src="script/search.js"></script>
<script src="script/pretty-print.js"></script>
<script src="script/inherited-summary.js"></script>
<script src="script/test-summary.js"></script>
<script src="script/inner-link.js"></script>
<script src="script/patch-for-local.js"></script>
</body>
</html>
